package com.example.wheelguide;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class FirstStepActivity extends Activity{
Button button1;
Database db;

@Override
protected void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	db = new Database(this);
	button1= new Button(this);
	setContentView(R.layout.first_step);
	
	
	button1= (Button) findViewById(R.id.Button_Personal_Profile);
	
	button1.setOnClickListener( new OnClickListener() {
		
		@Override
		public void onClick(View v) {
			Intent firstStepIntent= new Intent(v.getContext(),ProfileCreateActivity.class);
			startActivity(firstStepIntent);
		}
	});
	
button1= (Button) findViewById(R.id.Button_Wheel);
	
	button1.setOnClickListener( new OnClickListener() {
		
		@Override
		public void onClick(View v) {
			db.addProfil(new Wheelchair("SWheel", new Address("SWstr", "12", "65428", "Darmstadt"), true));
			Intent firstStepIntent= new Intent(v.getContext(),MainMenuActivity.class);
			startActivity(firstStepIntent);
			finish();
		}
	});
	
button1= (Button) findViewById(R.id.Button_E_Wheel);
	
	button1.setOnClickListener( new OnClickListener() {
		
		@Override
		public void onClick(View v) {
			db.addProfil(new ElectricWheelchair("SEWheel", new Address("SEWstr", "123", "64283", "Rue"), true));
			Intent firstStepIntent= new Intent(v.getContext(),MainMenuActivity.class);
			startActivity(firstStepIntent);
			finish();
		}
	});
	
	
	
	
	
	
button1= (Button) findViewById(R.id.Button_Chaperone);
	
	button1.setOnClickListener( new OnClickListener() {
		
		@Override
		public void onClick(View v) {
			db.addProfil(new Chaperone("SChaperone", new Address("SCstr", "212","64219", "Ruesselsheim"), true));
			Intent firstStepIntent= new Intent(v.getContext(),MainMenuActivity.class);
			startActivity(firstStepIntent);
			System.out.println("1");
			finish();
		}
	});
	
	
}

@Override
public boolean onCreateOptionsMenu(Menu menu) {
	// Inflate the menu; this adds items to the action bar if it is present.
	getMenuInflater().inflate(R.menu.activity_main, menu);
	return true;
}



	
	
	
}
